package client_gui;

import java.awt.BorderLayout;
import java.awt.EventQueue;
import java.awt.event.ActionListener;
import java.awt.event.WindowListener;

import javax.swing.JFrame;
import javax.swing.JPanel;
import javax.swing.border.EmptyBorder;
import javax.swing.JButton;

import client_controllers.EmployeeLoginController;
import client_controllers.MarketingEmployeeController;

public class MarketingEmployeeGUI extends JFrame {
	/**
	 * @class MarketingEmployeeGUI generates frame for marketing employees
	 */

	private JPanel contentPane;
	private JButton logout;
	private JButton DefineCampaignPattern;
	private JButton MaintainProduct;
	private JButton AnalysisSystem;
	MarketingEmployeeController mec;


	public MarketingEmployeeGUI(EmployeeLoginController elc) {
		setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
		this.setTitle("Marketing Employee");
		
		setBounds(100, 100, 450, 300);
		setLocationRelativeTo(null);
		contentPane = new JPanel();
		contentPane.setBorder(new EmptyBorder(5, 5, 5, 5));
		setContentPane(contentPane);
		contentPane.setLayout(null);
		
		logout = new JButton("Logout");
		logout.setBounds(176, 170, 89, 23);
		contentPane.add(logout);
		
		DefineCampaignPattern = new JButton("Define Campaign Pattern");
		DefineCampaignPattern.setBounds(107, 45, 226, 32);
		contentPane.add(DefineCampaignPattern);
		
		MaintainProduct = new JButton("Maintain Product");
		MaintainProduct.setBounds(107, 88, 226, 32);
		contentPane.add(MaintainProduct);
		
		AnalysisSystem = new JButton("Analysis System");
		AnalysisSystem.setBounds(107, 127, 226, 32);
		contentPane.add(AnalysisSystem);
		mec = new MarketingEmployeeController(this,elc);
		this.setVisible(true);
	}


	public JButton getLogout() {
		return logout;
	}

	public JButton getDefineCampaignPattern() {
		return DefineCampaignPattern;
	}

	public void setDefineCampaignPattern(JButton defineCampaignPattern) {
		DefineCampaignPattern = defineCampaignPattern;
	}

	public JButton getMaintainProduct() {
		return MaintainProduct;
	}

	public void setMaintainProduct(JButton maintainProduct) {
		MaintainProduct = maintainProduct;
	}

	public JButton getAnalysisSystem() {
		return AnalysisSystem;
	}

	public void setAnalysisSystem(JButton analysisSystem) {
		AnalysisSystem = analysisSystem;
	}

	public void setCampaignPatternLis( ActionListener lis) {
		this.DefineCampaignPattern.addActionListener(lis);

		
	}
	public void setMaintainProductLis(ActionListener lis) {
		this.MaintainProduct.addActionListener(lis);
		
	}
	public void setAnalysisSystemLis(ActionListener lis) {
		this.AnalysisSystem.addActionListener(lis);
		
	}
	public void setLogoutLis(ActionListener lis) {
		this.logout.addActionListener(lis);
		
	}
	public void setexittlis(WindowListener lis) {
		this.addWindowListener(lis);

		
	}
	

}
